package cn.sumpu.app.guoguojie.dao;

import java.util.List;
import java.util.Map;
import cn.sumpu.app.guoguojie.domain.Comment;
import cn.sumpu.app.guoguojie.exception.AppBusinessException;

public interface CommentDao {
	public void insert(Comment comment) throws AppBusinessException;

	public void updateComment(Comment comment) throws AppBusinessException;

	public void deleteCommentById(String id) throws AppBusinessException;

	public Comment getCommentById(String id) throws AppBusinessException;

	public int getCommentCountList(Map<String,Object> map)throws AppBusinessException;
	
	public int getCommentByOwnerTypeCount(Map <String, Object> map)throws AppBusinessException;
	
	//根据条件查询评论列表的长度
	int getCommentCountByBlogId(Map<String, Object> map) throws AppBusinessException;
	//根据BlogId批量屏蔽评论
	void updateByCommentIdList(Map<String, Object> map) throws AppBusinessException;
	//根据BlogId批量删除评论
	void deleteByCommentIdList(Map<String, Object> map) throws AppBusinessException;
	//根据条件批量删除评论(参数1.id:commentId 2.type:comment_id_type[可选])
	void deleteCommentByCondition(Map<String, Object> map) throws AppBusinessException;
	
	public List<Comment> getCommentByDoingId(Map<String, Object> map) throws AppBusinessException;//查询某一条微博的评论
	public int getCommentByDoingIdCount(Map<String, Object> map) throws AppBusinessException;//查询某一条微博的评论条数
	
	public void deleteCommentByCommentId (String commentId) throws AppBusinessException;
	
	public int getMyComCount(Map<String,Object> map)throws AppBusinessException;//获取用户家庭对别的用户总评论数
	
	public List<Comment> getCommentByDiscuss(Map<String, Object> map) throws AppBusinessException;
	
	 public int getCountByDiscuss(Map<String, Object> map) throws AppBusinessException;
	
}
